import user, { UserProps } from './user';
import editor, { EditorProps } from './editor';
import templates, { TemplatesProps } from './templates';

import { createStore } from 'vuex';

export interface GlobalDataProps {
  user: UserProps;
  templates: TemplatesProps;
  editor: EditorProps;
}
export interface ActionPayload {
  urlParams?: { [key: string]: any };
  data?: any;
  searchParams?: { [key: string]: any };
}
const store = createStore({
  modules: {
    editor,
    user,
    templates
  }
});

export default store;
